unit Unit2;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls;

type
  TForm2 = class(TForm)
    Edit1: TEdit;
  private
    { Private declarations }
  public
    procedure playpause;
    procedure mute;
    procedure maisvolume;
    procedure menosvolume;
  end;

var
  Form2: TForm2;

implementation

{$R *.dfm}

{ TForm2 }

procedure TForm2.maisvolume;
begin
  keybd_event(175, 0, KEYEVENTF_EXTENDEDKEY, 0);
  keybd_event(175, 0, KEYEVENTF_KEYUP, 0) ;
end;

procedure TForm2.menosvolume;
begin
  keybd_event(174, 0, KEYEVENTF_EXTENDEDKEY, 0);
  keybd_event(174, 0, KEYEVENTF_KEYUP, 0);
end;

procedure TForm2.mute;
begin
  keybd_event(173, 0, KEYEVENTF_EXTENDEDKEY, 0);
  keybd_event(173, 0, KEYEVENTF_KEYUP, 0) ;
end;

procedure TForm2.playpause;
begin
  keybd_event(179, 0, KEYEVENTF_EXTENDEDKEY, 0);
  keybd_event(179, 0, KEYEVENTF_KEYUP, 0);
end;

end.

